/**
 * @class ExtMVC.KohiveViewportBuilder
 * @extends ExtMVC.ViewportBuilder
 * Creates the Kohive viewport layout
 */
ExtMVC.KohiveViewportBuilder = Ext.extend(ExtMVC.ViewportBuilder, {

			/**
			 * Builds the Kohive viewport layout
			 */
			build	: function(os) {
				var config = os.getViewportBuilderConfig || {};

				// Apps
				os.applicationLauncher = new Kohive.views.os.ApplicationLauncher();

				// QuickApps
				os.quickAppsBar = new Kohive.views.os.QuickAppsBar();

				// Hive
				os.hiveSummary = new Kohive.views.hives.Summary();
				os.hiveOptions = new Kohive.views.hives.Options({
							renderTo	: Ext.getBody()
						});
				os.hivePanel = new Kohive.views.hives.Index({
							renderTo	: Ext.getBody()
						});

				// Member
				os.memberSummary = new Kohive.views.members.Summary();
				os.memberOptions = new Kohive.views.members.Options();
				os.memberPanel = new Kohive.views.members.Index();

				// Header
				// os.widgetBar = new Kohive.views.os.WidgetBar({});
				os.headerPanel = new Kohive.views.os.HeaderPanel({});

				os.windowManager = Ext.WindowMgr;

				// Viewport
				os.viewport = new Ext.Viewport({
							monitorResize	: true,
							layout			: 'border',

							items			: [{
										region	: 'north',
										baseCls	: '',
										cls		: '',
										height	: 33,
										// height: 130, with widget bar
										items	: [os.headerPanel// ,
										// os.widgetBar
										]
									}, {
										id			: 'kohive_viewport_desktop',
										region		: 'center',
										border		: false,
										bodyStyle	: 'background-color: transparent;'
									}]
						}
				);

				return os;
			}
		}
);

ExtMVC.ViewportBuilderManager.register('kohive', ExtMVC.KohiveViewportBuilder);